﻿using LK.WebAPI.appsettings;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using Microsoft.Extensions.Logging;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace LK.WebAPI.Controllers
{
    [ApiController]
    [Route("api/[controller]")]
    [ServiceFilter(typeof(LogAttribute))]//有参构造函数的标签打法
    public class BaseController : ControllerBase
    {
        [NonAction]
        public string Get()
        {
            throw new Exception("我是自定义异常");
            return "test";
        }
    }
}
